<?php
/*
 * Created on Sep 4, 2007 by Gabriel Pratt
 * For LN2_database
 */
 function createHomeDropDownBox ($query, $selected, $id) {
 	$select .= "<option value=\"\" > All </option>";
 	$select .= createDropDownBox($query, $selected, $id);
 	return $select;
 }
?>

<b>Filter By:</b> </br>
<table>
<tr>
	<td>
	Cell Type
	</td>
	<td>
	Modification
	</td>
	<td>
	Researcher
	</td>
	<td>
	Other Text
	</td>
</tr>
<tr>
<form action="Home.php" method="GET">
	<td>
	<select name="CellTypeID"> <!-- if in debug mode creatHomeDropDownBox will out put differenty -->
		Cell Type <? echo createHomeDropDownBox("SELECT Name, id FROM CellType ORDER BY Name ASC", $_GET['CellTypeID'], 'id') ?> 
	</select>
	</td>
	<td>
	<select name="ModifiedByID">
		Modification <? echo createHomeDropDownBox("SELECT Name, id FROM Modification ORDER BY Name ASC", $_GET['ModifiedByID'], 'id') ?> 
	</select>
	</td>
	<td>
	<select name="FrozenByID">
		Researcher <? echo createHomeDropDownBox("SELECT Name, id FROM Researcher ORDER BY Name ASC", $_GET['FrozenByID'], 'id') ?>
	</select>
	</td>
	<td>
		 <input type="text" name="textSearch" value="<?php echo $_GET['textSearch'] ?>">
	</td>
	<tr>
		<td>
			<input type="Submit" value="Search">
	</form>
	<!--Is this the best format? -->
		</td>
	</tr>
	<tr>
		<td>
			<form action="Home.php?CellTypeID=<?php echo getEmptyCellType() ?>&ModifiedByID=<?php echo getEmptyMod() ?>&FrozenByID=<?php echo getEmptyResearcher() ?>" method="GET">
			<input type="hidden" Name="CellTypeID" Value="<?php echo getEmptyCellType() ?>" >
			<input type="hidden" Name="ModifiedByID" value="<?php echo getEmptyMod() ?>">
			<input type="hidden" Name="FrozenByID" Value="<?php echo getEmptyResearcher() ?>">
			<input type="Submit" value="Find All Empty Tubes">
			</form>
		</td>
	</tr>
	<tr>
		<td>
		<?php echo searchButton($_GET); ?>
				</td>
	</tr>
	
	</table>

</br>


